package com.yang.factory;


public class FactoryTest {


    public static void main(String[] args) {
        // 生产保时捷
        Car porsche = CarFactory.getCar("porsche");
        porsche.create();
        // 生产五菱宏光
        Car sgmw = CarFactory.getCar("sgmw");
        sgmw.create();
        // 生产宝马
        Car bmw = CarFactory.getCar("bmw");
        bmw.create();
    }
}
